<template>
  <div>
    这是子组件num:{{ num1 }}
    <br>
    <hr>
    这是子组件num:{{ num2 }}
    <br>
    <hr>
    <button @click="mclick">修改num1的值</button>
    <button @click="nclick">修改num2的值</button>
  </div>
</template>

<script>
export default {
  props: {
    num1: {
      type: Number,
      required: true
    },
    num2: {
      type: Number,
      required: true
    }
  },
  methods: {
    mclick() {
      this.$emit('update:abc', this.num1 + 1)
    },
    nclick() {
      this.$emit('update:cde', this.num2 + 1)
    }
  }
}
</script>

<style>

</style>
